Copyright: Copyright © 1994 Global Majic Software, Inc.
Citation: Copyright © 1994 Global Majic Software, Inc.


Contents
Global Majic Software, Inc.

Instrument Custom Control Library

LED Control

Properties	Events	Product Support	Copyright

Description:

This control displays a variety of LED styles including rectangular, circular, and user supplied bitmaps.  The control can display a single LED as an on/off indicator or it may be configured as an array of horizontal or vertical LEDs to indicate an array of on/off indicators (Bitwise Mode) or a gauge or linear meter (Value Mode).  The mouse can be used for input when the MouseControl property is set to True.  The control include bevels for a 3D appearance.


Product Support

Product support for Instrument Custom Control Library is available to registered users by contacting Global Majic Software, Inc. at the following locations:

Global Majic Software, Inc.

P.O. Box 322

Madison, Alabama  35758

CompuServe:  73261,3642

Internet:   73261.3642@compuserve.com

Product Support is free for a period of three (3) months from the date of registration.


Events
Events:

Change

Click

GotFocus

LostFocus


BevelOuter
BevelOuter Property

Description

Sets or returns the outer shadow style of the control.

Usage

[form.]control.BevelOuter[ = integer ]

Setting

The BevelOuter property settings are:

Setting 	Description

0	None

1	Raised

2	Inset

Remarks

This property has no affect when BevelWidth=0.  This property is used in conjunction with BevelInner, BevelWidth, and BorderWidth.

Data Type

Integer (Enumerated)


BevelInner
BevelInner Property

Description

Sets or returns the inner shadow style of the control.

Usage

[form.]control.BevelInner[ = integer ]

Setting

The BevelInner property settings are:

Setting 	Description

0	None

1	Raised

2	Inset

Remarks

This property has no affect when BevelWidth=0.  This property is used in conjunction with BevelOuter, BevelWidth, and BorderWidth.

Data Type

Integer (Enumerated)


BevelWidth
BevelWidth Property

Description

Sets or returns the shadow sizes of the inner and outer bevels of the control.

Usage

[form.]control.BevelWidth[ = integer ]

Remarks

This property works in conjunction with BevelInner, BevelOuter and BorderWidth.

Data Type

Integer


BorderWidth
BorderWidth Property

Description

Sets or returns the border size between the inner and outer bevels of the control.

Usage

[form.]control.BorderWidth[ = integer ]

Remarks

This property works in conjunction with BevelInner, BevelOuter and BevelWidth.

Data Type

Integer


MouseControl
MouseControl Property

Description

Enables and disables mouse input to the control.

Usage

[form.]control.MouseControl[ = {TRUE|FALSE} ]

Setting

The MouseControl property settings are:

Setting 	Description

True	Allows the control's Value to be modified with mouse input.

False	Disables mouse input to the control.

Data Type

Integer (Boolean)


Value
Value Property

Description

Sets or returns the control's displayed value.

Usage

[form.]control.Value[ = float ]

Remarks

This property has two possible uses, depending on the Mode property setting.  If Mode = 0, then the Value corresponds to the number of LEDs turned "on".  However, if Mode = 1, then the Value may be used to set the LEDs LEDStatus property.  The Value may also be returned by setting the LEDStatus property of individual LEDs by using the mouse.

Data Type

Long


copyright
COPYRIGHT INFORMATION

All Global Majic Software, Inc. software programs, shareware, and freeware are protected under the copyright laws of the United States and foreign countries. All rights are reserved to Global Majic Software, Inc. Violations of copyright laws are investigated by the FBI. Distribution of Global Majic Software, Inc. products implies that you have read and agreed to the distribution terms described below:

INTENT

Global Majic Software, Inc. seeks to distribute its shareware as widely as possible. However, we want the end-users of our software to be properly informed that it is shareware.

DISTRIBUTOR INFORMATION AND LICENSE INFORMATION

The license information and distribution requirements in this document supersede all previous license statements. To continue to distribute Global Majic Software, Inc. products, you must adhere to the licensing and distribution requirements below.

If you are a mail order or BBS-type distributor of shareware software, you may distribute these programs as they are, without any changes other than expanding files contained in the ZIP archives. However, you have the responsibility to check from time to time, at a minimum interval of 6 months, for new versions of these programs, and to update your copies in a timely manner. Global Majic Software, Inc. will gladly send you a diskette containing the current versions on request.

You must fully identify all Global Majic Software, Inc. programs in your advertising, by the program's full name and version, and indicate the registration fee in the program description. The words Global Majic Software, Inc. must appear in all program descriptions.

SHAREWARE DISCLOSURE REQUIRED

All advertising and packaging information including references to Global Majic Software, Inc. products must contain a statement explaining the shareware concept.  Specifically, that statement must explain that shareware software MUST be registered by the user, after a trial period, by paying a registration fee, and that all monies paid for the shareware version are duplication and distribution charges only. All such statements must be clearly displayed in a position where they are likely to be read by potential customers.

RETAIL RACK AND CD-ROM DISTRIBUTION

If you distribute shareware in a retail setting in racks, store displays, vending machines, at computer fairs, or in any way other than normal BBS or catalog-based sales, you must contact Global Majic Software, Inc. for permission to distribute any Global Majic Software, Inc. program. Rack or retail-like sales require a special distribution license, normally requiring royalties paid to Global Majic Software, Inc. If you distribute shareware on CD-ROM disks, you must also contact Global Majic Software, Inc. before including any Global Majic Software, Inc. shareware programs on a CD-ROM disk. Normally, permission is granted, but current versions must be included and all old versions of any Global Majic Software, Inc. program removed from any CD-ROM disk containing Global Majic Software, Inc. products.


BackgroundPicture
BackgroundPicture Property

Description

Determines the background graphic to be displayed in the LED control.

Usage

[form.]control.BackgroundPicture[ = picture ]

Setting

The BackgroundPicture property settings are:

Setting 	Description

(none)	No picture is displayed.

(bitmap)	At design-time, specify the bitmap file name to be displayed.  At run-time, specify the bitmap using the LoadPicture function.

Remarks

When setting the picture at design-time, the picture will be saved with the form, and will be compiled into the executable.  When the BackgroundPicture property is set to (none), the BackColor property is used to fill the background of the control.

Data Type

Integer


AutoSize
AutoSize Property

Description

Enables the control to automatically size itself to fit its contents.

Usage

[form.]control.AutoSize[ = {TRUE|FALSE} ]

Setting

The AutoSize property settings are:

Setting 	Description

TRUE	Automatically sizes itself to fit its contents.

FALSE	Allows the width and height of the control to be set manually.

Data Type

Integer (Boolean)


LED Props
Properties:

AutoSize	Index	OffPictureGreen
BackColor	LEDColor	OffPictureRed
BackgroundPicture	LEDHeight	OffPictureYellow
BevelInner	LEDIndex	OnPictureGreen
BevelOuter	LEDSep	OnPictureRed
BevelWidth	LEDStatus	OnPictureYellow
BorderHorizontal	LEDStyle	TabIndex
BorderVertical	LEDWidth	TabStop
BorderWidth	Left	Tag
DecayRate	MaxDecay	Top
Direction	Mode	Value
Enabled	MouseControl	Visible
Height	Name	Width
HelpContextID	NumLEDs


LED BorderVert
BorderVertical Property

Description

Sets or returns the vertical border size of the control.  This defines the distance between the top edge of the control and the position of the upper left portion of the first LED.

Usage

[form.]control.BorderVertical[ = integer ]

Remarks

This property works in conjunction with BorderHorizontal.

Data Type

Integer


LED Mode
Mode Property

Description

Selects the analysis method of the Value property.

Usage

[form.]control.Mode[ = integer ]

Setting

The Mode property settings are:

Setting 	Description

0	The Value property determines the number of LEDs "on"

1	Perform at bitwise analysis on the Value property

Data Type

Integer (Enumerated)


LED Events
Events:

Click

GotFocus

LostFocus


LED BorderHoriz
BorderHorizontal Property

Description

Sets or returns the horizontal border size of the control.  This defines the distance between the left edge of the control and the position of the upper left portion of the first LED.

Usage

[form.]control.BorderHorizontal[ = integer ]

Remarks

This property works in conjunction with BorderVertical.

Data Type

Integer


LED Direction
Direction Property

Description

Selects either a forward or backward fill for the LEDs.

Usage

[form.]control.Direction[ = integer ]

Setting

The Direction property settings are:

Setting 	Description

0	Forward.  This is left to right for horizontal Orientation and top to bottom for vertical Orientation.

1	Backward.  This is right to left for horizontal Orientation bottom to top for vertical Orientation.

Data Type

Integer (Enumerated)


LED Orientation
Orientation Property

Description

Selects either a horizontal or vertical positioning of the LEDs.

Usage

[form.]control.Orientation[ = integer ]

Setting

The Orientation property settings are:

Setting 	Description

0	Horizontal

1	Vertical

Data Type

Integer (Enumerated)


LED Style
LEDStyle Property

Description

Selects the display type for the LEDs.

Usage

[form.]control.LEDStyle[ = integer ]

Setting

The LEDStyle property settings are:

Setting 	Description

0	Rectangular

1	Circular

2	Bitmap (uses User supplied bitmaps for the LEDs)

Data Type

Integer (Enumerated)


LED Color
LEDColor Property

Description

Selects the color for each LED.

Usage

[form.]control.LEDColor[ = integer ]

Setting

The LEDColor property settings are:

Setting 	Description

0	Red

1	Yellow

2	Green

Remark

If LEDStyle=2 (bitmap), color is set using this property in conjunction with the bitmap properties: OnPictureRed, OffPictureRed, OnPictureYellow, OffPictureYellow, OnPictureGreen, and OffPictureGreen. For example, if a multicolored bitmap LED display is desired, the LEDColor property controls which bitmap property (listed above) is accessed.

Data Type

Integer (Enumerated)


LED OnPictureGreen
OnPictureGreen Property

OnPictureYellow Property

OnPictureRed Property

Description

Determines the graphic to be displayed when the LED control's LEDStyle = 2 (bitmap) and the LED is turned on.  Although a color is referenced in the name of the property, it in no way limits the color of the bitmap.  It merely allows the bitmaps to be selected by the LEDColor property.

Usage

[form.]control.OnPictureGreen[ = picture ]

[form.]control.OnPictureYellow[ = picture ]

[form.]control.OnPictureRed[ = picture ]

Setting

The property settings are:

Setting 	Description

(none)	No picture is displayed.

(bitmap)	At design-time, specify the bitmap file name to be displayed.  At run-time, specify the bitmap using the LoadPicture function.

Remarks

When setting the picture at design-time, the picture will be saved with the form, and will be compiled into the executable.

Data Type

Integer


LED Index
LEDIndex Properties

Description

Used to assign properties to individual LEDs.  Each LED has a unique LEDIndex.

Usage

[form.]control.LEDIndex[ = integer ]

Remarks

The LEDColor and LEDStatus may be set separately for each LED.  These properties are referenced through the LEDIndex property.  For example, for a Green LED, turned "on", in the 4th position:

LED1.LEDIndex=3  //numbering starts with 0

LED1.LEDColor=2

LED1.LEDStatus=1

Data Type

Integer


LED OffPictureGreen
OffPictureGreen Property

OffPictureYellow Property

OffPictureRed Property

Description

Determines the graphic to be displayed when the LED control's LEDStyle = 2 (bitmap) and the LED is turned off.  Although a color is referenced in the name of the property, it in no way limits the color of the bitmap.  It merely allows the bitmaps to be selected by the LEDColor property.

Usage

[form.]control.OffPictureGreen[ = picture ]

[form.]control.OffPictureYellow[ = picture ]

[form.]control.OffPictureRed[ = picture ]

Setting

The property settings are:

Setting 	Description

(none)	No picture is displayed.

(bitmap)	At design-time, specify the bitmap file name to be displayed.  At run-time, specify the bitmap using the LoadPicture function.

Remarks

When setting the picture at design-time, the picture will be saved with the form, and will be compiled into the executable.

Data Type

Integer


LED Status
LEDStatus Property

Description

Selects the "on" or "off" status of the given LED.

Usage

[form.]control.LEDStatus[ = integer ]

Setting

The LEDStatus property settings are:

Setting 	Description

0	Off

1	On

Remarks

Individual LEDs can be turned "on" using the LEDStatus property only if the Mode property is set to "bitwise."

Data Type

Integer (Enumerated)


LED Width
LEDHeight, LEDWidth, LEDSep Properties

Description

Determines the dimensions of an LED and the spacing between multiple LEDs.

Usage

[form.]control.LEDHeight[ = integer ]

[form.]control.LEDWidth[ = integer ]

[form.]control.LEDSEP[ = integer ]

Remarks

The LEDWidth is the dimension between the left and right edges of the LED.  The LEDHeight is the dimension between the top and bottom edges of the LED.  If multiple LEDs reside in the control then each LED is separated by the dimension specified in the LEDSep property.

Data Type

Integer


LED NumLEDs
NumLEDs Property

Description

Defines the number of LEDs in the given control.

Usage

[form.]control.NumLEDs[ = integer ]

Data Type

Integer


DecayRate
DecayRate Property

Description

Determines the rate (in milliseconds) at which the maximum marker decays.

Usage

[form.]control.DecayRate[ = milliseconds ]

Remarks

This property only applies when MaxDecay = TRUE.

Data Type

Integer


MaxDecay
MaxDecay Property

Description

Enables and dissables the maximum marker for the LED control.

Usage

[form.]control.MaxDecay[ = {TRUE|FALSE} ]

Setting

The MaxDecay property settings are:

Setting 	Description

True	Enables the maximum marker to be displayed.

False	Disables the maximum marker.

Remarks

This property works in relation to DecayRate.

Data Type

Integer (Boolean)